.class Lcom/example/m6wmr/ShopimgActivity$3;
.super Ljava/lang/Thread;
.source "ShopimgActivity.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lcom/example/m6wmr/ShopimgActivity;->getShopSource()Z
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic this$0:Lcom/example/m6wmr/ShopimgActivity;


# direct methods
.method constructor <init>(Lcom/example/m6wmr/ShopimgActivity;)V
    .locals 0

    .prologue
    .line 1
    iput-object p1, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    .line 263
    invoke-direct {p0}, Ljava/lang/Thread;-><init>()V

    return-void
.end method


# virtual methods
.method public run()V
    .locals 14

    .prologue
    const/4 v13, 0x2

    .line 265
    invoke-super {p0}, Ljava/lang/Thread;->run()V

    .line 267
    new-instance v5, Landroid/os/Message;

    invoke-direct {v5}, Landroid/os/Message;-><init>()V

    .line 269
    .local v5, "msg":Landroid/os/Message;
    new-instance v10, Ljava/lang/StringBuilder;

    iget-object v11, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v11, v11, Lcom/example/m6wmr/ShopimgActivity;->m:Lmyapp/MyApp;

    invoke-virtual {v11}, Lmyapp/MyApp;->getWebConfig()Ljava/lang/String;

    move-result-object v11

    invoke-static {v11}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v11

    invoke-direct {v10, v11}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    .line 270
    const-string v11, "/index.php?ctrl=app&action=getShopRealInfo&shopid="

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    iget-object v11, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    # getter for: Lcom/example/m6wmr/ShopimgActivity;->shopid:Ljava/lang/String;
    invoke-static {v11}, Lcom/example/m6wmr/ShopimgActivity;->access$6(Lcom/example/m6wmr/ShopimgActivity;)Ljava/lang/String;

    move-result-object v11

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    const-string v11, "&datatype=json"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 269
    invoke-virtual {v10}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v9

    .line 271
    .local v9, "url":Ljava/lang/String;
    const-string v10, "ShopshowACtivity"

    new-instance v11, Ljava/lang/StringBuilder;

    const-string v12, "getshopSource\uff08\uff09\u83b7\u53d6\u5e97\u94fa\u4fe1\u606f"

    invoke-direct {v11, v12}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v11, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v11

    invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v11

    invoke-static {v10, v11}, Lmyapp/Mylog;->d(Ljava/lang/String;Ljava/lang/String;)V

    .line 272
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v10, v10, Lcom/example/m6wmr/ShopimgActivity;->m:Lmyapp/MyApp;

    invoke-static {v9, v10}, LPlugclass/HttpConn;->getStr(Ljava/lang/String;Lmyapp/MyApp;)Ljava/lang/String;

    move-result-object v8

    .line 273
    .local v8, "str":Ljava/lang/String;
    const-string v10, "str----------------"

    invoke-static {v10, v8}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I

    .line 275
    :try_start_0
    new-instance v4, Lorg/json/JSONObject;

    invoke-direct {v4, v8}, Lorg/json/JSONObject;-><init>(Ljava/lang/String;)V

    .line 277
    .local v4, "json":Lorg/json/JSONObject;
    const-string v10, "error"

    invoke-virtual {v4, v10}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v10

    const-string v11, "true"

    invoke-virtual {v10, v11}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v10

    if-eqz v10, :cond_0

    .line 279
    const-string v10, "msg"

    invoke-virtual {v4, v10}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v10

    iput-object v10, v5, Landroid/os/Message;->obj:Ljava/lang/Object;

    .line 280
    const/4 v10, 0x1

    iput v10, v5, Landroid/os/Message;->arg1:I

    .line 281
    sget-object v10, Lcom/example/m6wmr/ShopimgActivity;->h:Landroid/os/Handler;

    invoke-virtual {v10, v5}, Landroid/os/Handler;->sendMessage(Landroid/os/Message;)Z

    .line 321
    .end local v4    # "json":Lorg/json/JSONObject;
    :goto_0
    return-void

    .line 284
    .restart local v4    # "json":Lorg/json/JSONObject;
    :cond_0
    const-string v10, "msg"

    invoke-virtual {v4, v10}, Lorg/json/JSONObject;->isNull(Ljava/lang/String;)Z

    move-result v10

    if-eqz v10, :cond_1

    .line 286
    const/4 v10, 0x2

    iput v10, v5, Landroid/os/Message;->arg1:I

    .line 287
    sget-object v10, Lcom/example/m6wmr/ShopimgActivity;->h:Landroid/os/Handler;

    invoke-virtual {v10, v5}, Landroid/os/Handler;->sendMessage(Landroid/os/Message;)Z
    :try_end_0
    .catch Lorg/json/JSONException; {:try_start_0 .. :try_end_0} :catch_0

    goto :goto_0

    .line 313
    .end local v4    # "json":Lorg/json/JSONObject;
    :catch_0
    move-exception v0

    .line 315
    .local v0, "e":Lorg/json/JSONException;
    invoke-virtual {v0}, Lorg/json/JSONException;->printStackTrace()V

    .line 318
    iput v13, v5, Landroid/os/Message;->arg1:I

    .line 319
    sget-object v10, Lcom/example/m6wmr/ShopimgActivity;->h:Landroid/os/Handler;

    invoke-virtual {v10, v5}, Landroid/os/Handler;->sendMessage(Landroid/os/Message;)Z

    goto :goto_0

    .line 290
    .end local v0    # "e":Lorg/json/JSONException;
    .restart local v4    # "json":Lorg/json/JSONObject;
    :cond_1
    :try_start_1
    const-string v10, "msg"

    invoke-virtual {v4, v10}, Lorg/json/JSONObject;->getJSONObject(Ljava/lang/String;)Lorg/json/JSONObject;

    move-result-object v6

    .line 291
    .local v6, "obj":Lorg/json/JSONObject;
    const-string v10, "shopRealInfo"

    invoke-virtual {v6, v10}, Lorg/json/JSONObject;->getJSONArray(Ljava/lang/String;)Lorg/json/JSONArray;

    move-result-object v7

    .line 292
    .local v7, "shopinfo":Lorg/json/JSONArray;
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    new-instance v11, Ljava/util/ArrayList;

    invoke-direct {v11}, Ljava/util/ArrayList;-><init>()V

    iput-object v11, v10, Lcom/example/m6wmr/ShopimgActivity;->listcx:Ljava/util/List;

    .line 294
    const/4 v1, 0x0

    .local v1, "i":I
    :goto_1
    invoke-virtual {v7}, Lorg/json/JSONArray;->length()I

    move-result v10

    if-lt v1, v10, :cond_2

    .line 309
    iput-object v8, v5, Landroid/os/Message;->obj:Ljava/lang/Object;

    .line 311
    const/4 v10, 0x3

    iput v10, v5, Landroid/os/Message;->arg1:I

    .line 312
    sget-object v10, Lcom/example/m6wmr/ShopimgActivity;->h:Landroid/os/Handler;

    invoke-virtual {v10, v5}, Landroid/os/Handler;->sendMessage(Landroid/os/Message;)Z

    goto :goto_0

    .line 296
    :cond_2
    invoke-virtual {v7, v1}, Lorg/json/JSONArray;->getJSONObject(I)Lorg/json/JSONObject;

    move-result-object v10

    const-string v11, "imglist"

    invoke-virtual {v10, v11}, Lorg/json/JSONObject;->getJSONArray(Ljava/lang/String;)Lorg/json/JSONArray;

    move-result-object v2

    .line 297
    .local v2, "imgs":Lorg/json/JSONArray;
    const/4 v3, 0x0

    .local v3, "j":I
    :goto_2
    invoke-virtual {v2}, Lorg/json/JSONArray;->length()I

    move-result v10

    if-lt v3, v10, :cond_3

    .line 294
    add-int/lit8 v1, v1, 0x1

    goto :goto_1

    .line 298
    :cond_3
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    new-instance v11, Lbean/Shopimg;

    invoke-direct {v11}, Lbean/Shopimg;-><init>()V

    iput-object v11, v10, Lcom/example/m6wmr/ShopimgActivity;->sb:Lbean/Shopimg;

    .line 299
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v10, v10, Lcom/example/m6wmr/ShopimgActivity;->sb:Lbean/Shopimg;

    invoke-virtual {v7, v1}, Lorg/json/JSONArray;->getJSONObject(I)Lorg/json/JSONObject;

    move-result-object v11

    const-string v12, "name"

    invoke-virtual {v11, v12}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v11

    invoke-virtual {v10, v11}, Lbean/Shopimg;->setType(Ljava/lang/String;)V

    .line 300
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v10, v10, Lcom/example/m6wmr/ShopimgActivity;->sb:Lbean/Shopimg;

    invoke-virtual {v7, v1}, Lorg/json/JSONArray;->getJSONObject(I)Lorg/json/JSONObject;

    move-result-object v11

    const-string v12, "name"

    invoke-virtual {v11, v12}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v11

    invoke-virtual {v10, v11}, Lbean/Shopimg;->setName(Ljava/lang/String;)V

    .line 301
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v10, v10, Lcom/example/m6wmr/ShopimgActivity;->sb:Lbean/Shopimg;

    invoke-virtual {v2, v3}, Lorg/json/JSONArray;->getJSONObject(I)Lorg/json/JSONObject;

    move-result-object v11

    const-string v12, "img"

    invoke-virtual {v11, v12}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v11

    invoke-virtual {v10, v11}, Lbean/Shopimg;->setImg(Ljava/lang/String;)V

    .line 302
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v10, v10, Lcom/example/m6wmr/ShopimgActivity;->sb:Lbean/Shopimg;

    invoke-virtual {v2, v3}, Lorg/json/JSONArray;->getJSONObject(I)Lorg/json/JSONObject;

    move-result-object v11

    const-string v12, "id"

    invoke-virtual {v11, v12}, Lorg/json/JSONObject;->getString(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v11

    invoke-virtual {v10, v11}, Lbean/Shopimg;->setId(Ljava/lang/String;)V

    .line 303
    iget-object v10, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v10, v10, Lcom/example/m6wmr/ShopimgActivity;->listcx:Ljava/util/List;

    iget-object v11, p0, Lcom/example/m6wmr/ShopimgActivity$3;->this$0:Lcom/example/m6wmr/ShopimgActivity;

    iget-object v11, v11, Lcom/example/m6wmr/ShopimgActivity;->sb:Lbean/Shopimg;

    invoke-interface {v10, v11}, Ljava/util/List;->add(Ljava/lang/Object;)Z
    :try_end_1
    .catch Lorg/json/JSONException; {:try_start_1 .. :try_end_1} :catch_0

    .line 297
    add-int/lit8 v3, v3, 0x1

    goto :goto_2
.end method

.method public declared-synchronized start()V
    .locals 1

    .prologue
    .line 324
    monitor-enter p0

    :try_start_0
    invoke-super {p0}, Ljava/lang/Thread;->start()V
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    .line 325
    monitor-exit p0

    return-void

    .line 324
    :catchall_0
    move-exception v0

    monitor-exit p0

    throw v0
.end method
